cmake_minimum_required(VERSION 3.15)
project(nosal-exec VERSION 1.0.0 LANGUAGES C CXX)

# Threads using pthread
set(THREADS_PREFER_PTHREAD_FLAG ON)
#find_package(Threads REQUIRED)

# Load and run CMake code from a file or module
include(FindPkgConfig)
include(CMakePackageConfigHelpers)
include(GNUInstallDirs)
include(NOSAL/nosal)
include(NOSAL/toolchain_qnx700_aarch64)


# Enable tests
if(NOSAL_ENABLE_TESTS)
    message(STATUS "PROJECT MESSAGE: Execution Management tests are enabled")
    enable_testing()
endif()

# Look for required packages
find_package(nosal-log REQUIRED)
find_package(nosal-core REQUIRED)

# Set global variabels
set(NOSAL_CMAKE_INSTALL_BINTESTDIR ${APD_CMAKE_INSTALL_BINTESTDIR})

add_subdirectory(src)
